/*
 * stub_get_inode.c
 *
 *  Created on: Oct 26, 2009
 *      Author: godinho
 */
#include <inode.h>
#include <directory.h>
#include <stdlib.h>
#include <stdio.h>
#include <pcb.h>

PCB pcb;

int get_inode(inode* i, int inodeNum){

	switch(inodeNum){
	case 0:
			i->tipo_arquivo = 'd';
			i->direct_blocks[0] = 5000;
			i->f_size = 3* sizeof(d_name);

		break;
	case 1:
			i->tipo_arquivo = 'f';
		break;
	}

	return 0;
}

int search_dir(inode* i, char* name){
	return 1;
}

int busca_inode(char *caminho);

int main(){

	pcb.current_dir = 0;

	int nr_teste_txt = busca_inode("/teste.txt");

	printf("Nr inode teste.txt: %d\n", nr_teste_txt);

	return 0;
}
